Server Side Environment


Servlet Concept


Server side programs can be written using different server-side technologies, such as Common Gateway Interface (CGI), Active Server Pages (ASP) and Servlets.
CGI scripts are written in C, C++ or perl programming languages.
In case of an application using CGI script to process client request, the server creates a separate instance of the CGI script to process the request.
As a result,the efficiency of the server is affected when there is large number of concurrent requests.

Regard Server Side Technology


ASP is a server-side technology that enables a developer to combine both HTML and scripting language in the same page.
ASP objects are multithreading and can therefore concurrently service multiple requests.
The limitation of the ASP is that it is not compatible with all the commercial Web servers.

Description about Servlet


Servlets are server side programs written in Java.
Unlike CGI scripts, the servlet initialization code is executed only once.
Moreover, separate thread in the server handle each client-request.
In addition, servlets inherit all the features of the Java programming language.

Web containers


Web containers provide various services required by web application, such as
Managing various stages in the life cycle of the servlet, such as initializing a servlet instance, processing the client request,
and removing the servlet instance from service.
Defining the security constraints that specifies only authorized users can access the deployed servlets.
Managing database transactions when a servlet needs to read and write data from a database, such as SQL Server 2000.
Creating and removing servlet instances from an instance pool to serve multiple requests.